
<meta charset="utf-8">
<script>
    var sum = 0;
    var i = 1;
    while(i<=100){
        sum=sum+i;
        i++;
    }
    alert(sum);
</script>